<template>
  <div>
    <van-nav-bar title="个人信息" left-arrow right-text="保存" />
    <van-cell-group>
      <van-cell title="头像" is-link>
        <van-image
          round
          width="30"
          height="30"
          fit="cover"
          src="http://toutiao.meiduo.site/FgSTA3msGyxp5-Oufnm5c0kjVgW7"
        />
      </van-cell>
      <van-cell title="昵称" value="abc" is-link />
      <van-cell title="性别" value="男" is-link />
      <van-cell title="生日" value="2019-9-27" is-link />
    </van-cell-group>
  </div>
</template>

<script>
// 导入获取当前用户资料请求接口
import { getUserModifyInfo } from '@/api/users'
export default {
  name: 'UserIndex',
  data () {
    return {
      // 当前用户个人资料
      user: {}
    }
  },
  created () {
    this.getUserInfo()
  },
  methods: {
    async getUserInfo () {
      try {
        const { data } = await getUserModifyInfo()
        this.user = data.data
      } catch (err) {
        console.dir()
      }
    }
  }
}
</script>

<style lang="less" scoped>

</style>
